<!--
 * @Description: 
 * @Author: mmzhang
 * @Date: 2022-11-21 17:18:37
 * @LastEditTime: 2022-12-02 17:11:27
-->
<template>
  <div class="pro-content">
    <Tabs type="card" v-model="showTab" :animated="false">
      <TabPane label="霸屏神器" name="shortArticalStatistics">
        <short-artical-statistics ref="shortArticalStatistics"
          v-if="showTab=='shortArticalStatistics'"></short-artical-statistics>
      </TabPane>
      <TabPane label="发文章" name="importArticleLog">
        <import-article-log ref="importArticleLog" v-if="showTab=='importArticleLog'">
        </import-article-log>
      </TabPane>
      <TabPane label="发海报" name="posterRecord">
        <poster-record ref="posterRecord" v-if="showTab=='posterRecord'">
        </poster-record>
      </TabPane>
    </Tabs>
  </div>
</template>
<script>
  import importArticleLog from './components/proLog/importArticleLog.vue'
  import shortArticalStatistics from './components/proLog/shortArticalStatistics.vue'
  import posterRecord from './components/proLog/posterRecord.vue'
  import dt from '@dt/dt'
  export default {
    data() {
      return {
        showTab: 'shortArticalStatistics'
      }
    },
    components: {
      importArticleLog,
      shortArticalStatistics,
      posterRecord
    },
    watch: {
      showTab(val, oldVal) {
        dt.session.set('proShowTab', val)
      }
    },
    mounted() {
      this.showTab = dt.session.get('proShowTab') ? dt.session.get('proShowTab') :
        'shortArticalStatistics'
    }
  }
</script>
<style lang="scss" scoped>
  .pro-content {
    padding: 20px;

    .ivu-tabs {
      height: 100%;

      ::v-deep .ivu-tabs-content {
        height: 100%;

        .ivu-tabs-tabpane {
          height: 100%;
        }
      }
    }

  }
</style>